package com.letukeji.web.riverdelictmanagement.bean;

import java.io.Serializable;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * (User)实体类
 *
 * @author 陈华强
 * @since 2019-10-22 13:13:10
 */
@Data
public class User implements Serializable {
    private static final long serialVersionUID = 396525154344131416L;
    //用户id
    private Integer id;

    @NotBlank(message = "用户名不能为空")
    @Length(min = 1, max = 6, message = "用户名长度为1-6")
    private String username;

    @Length(min = 6,max = 20)
    private String password;

    @Email(message = "邮箱格式不正确")
    private String email;

    private String openid;
    private String avatar;

    @NotBlank(message = "手机号不能为空")
    private String phone;
    private int role_id;
    private char disable;
    private String nickname;
    private String company;
    private String state;
    private int bind_state;
    private String memo;
    private String create_time;
    private String create_user;
    private String last_login;
    private String last_ip;

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public int getRole_id() {
        return role_id;
    }

    public void setRole_id(int role_id) {
        this.role_id = role_id;
    }

    public char getDisable() {
        return disable;
    }

    public void setDisable(char disable) {
        this.disable = disable;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getCompany() {
        return company;
    }

    public void setCompany(String company) {
        this.company = company;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public int getBind_state() {
        return bind_state;
    }

    public void setBind_state(int bind_state) {
        this.bind_state = bind_state;
    }

    public String getMemo() {
        return memo;
    }

    public void setMemo(String memo) {
        this.memo = memo;
    }

    public String getCreate_time() {
        return create_time;
    }

    public void setCreate_time(String create_time) {
        this.create_time = create_time;
    }

    public String getCreate_user() {
        return create_user;
    }

    public void setCreate_user(String create_user) {
        this.create_user = create_user;
    }

    public String getLast_login() {
        return last_login;
    }

    public void setLast_login(String last_login) {
        this.last_login = last_login;
    }

    public String getLast_ip() {
        return last_ip;
    }

    public void setLast_ip(String last_ip) {
        this.last_ip = last_ip;
    }
}